<template>
    <div>
        <div data-role="page" id="pageone">
    <div class="handline-con">
        <h2 class="title">{{listText.activityTitle}}</h2>
        <div class="user-info">
            <a href="javascript:void (0)" class="name">龙蛙网</a>
            <span class="time">2天前</span>
        </div>
        <div class="text-content" v-html="listText.activityContent">
            {{listText.activityContent}}
     
        </div>
    </div>
    <div class="rm-comment" v-show="false">
        <span class="comment-title">热门评论</span>
        <ul class="comment-ul">
            <li class="list-li">
                <div class="left">
                    <img src="../../assets/personal/images/touxiang.png" alt="" class="touxiang">
                </div>
                <div class="center">
                    <p class="name">木子</p>
                    <p class="time">11小时前</p>
                    <p class="text">共享新零售期待</p>
                </div>
                <div class="right">
                    <i class="icon"></i>
                    <span class="num">点赞</span>
                </div>
            </li>
            <li class="list-li">
                <div class="left">
                    <img src="images/touxiang.png" alt="" class="touxiang">
                </div>
                <div class="center">
                    <p class="name">木子</p>
                    <p class="time">11小时前</p>
                    <p class="text">共享新零售期待</p>
                </div>
                <div class="right">
                    <i class="icon"></i>
                    <span class="num">点赞</span>
                </div>
            </li>
        </ul>
        <router-link href="#pagetwo" class="all-comment" data-transition="slide" :to="{name:'headline_text'}"> 查看全部评论<i class="icon"></i></router-link>
    </div>

</div>
<router-link href="index.html" class="backTo" data-ajax="false" :to="{name:'Index'}">返回</router-link>
    </div>
</template>
<style scoped>
  @import "../../../src/assets/personal/css/handline.css";
  @import "../../../src/assets/personal/css/style.css";
</style>
<script>
export default {
     mounted(){
         $(function () {
    $(".rm-comment .comment-ul .list-li .right .icon").click(function () {
        if($(this).hasClass('active')){
            $(this).siblings(".num").html("点赞");
            $(this).removeClass("active");
            $(this).siblings(".num").removeClass("active");
        }else{
            $(this).addClass("active");
            $(this).siblings(".num").addClass("active");
            var num = 10;
            $(this).siblings(".num").html(num+1);
        }

    })

    $(".comment-info .zan-info .icon-num .icon").click(function () {
        if($(this).hasClass('active')){
            $(this).siblings(".num").html("32");
            $(this).removeClass("active");
            $(this).siblings(".num").removeClass("active");
        }else{
            $(this).addClass("active");
            $(this).siblings(".num").addClass("active");
            var num = 32;
            $(this).siblings(".num").html(num+1);
        }
    });

    $(".send-comment-info .send-input").focus(function () {
         if($(this).value!=""){
             $(".send-comment-info .send-sub").show();
         }else {
             $(".send-comment-info .send-sub").hide();
         }
    });
    $(".rm-comment .comment-ul .list-li .right .icon-pl").click(function () {
        $(".pagethree-con input").trigger("click").focus();
    });
})
     }
}
</script>
<script>
export default {
    data () {
        return {
            textid:0,
            listText:[]
        }
    },
    methods: {
        text(){
            this.textid=this.$route.params.id;
             this.$http.get(this.APIURL_PREFIX+"/api/wap/activities/"+this.textid).then((response) => {
              this.listText=response.data.data;
				}).catch(function(err){
					console.log(err)
        });
        }
    }
    ,mounted(){
        this.text();
    }
}
</script>
